import request from '@/utils/request'
export function add(data) {
  return request({
    url: 'rest/api/manager/service',
    method: 'post',
    data
  })
}

/**
 * 分页查询服务信息
 * @param params
 * @returns {AxiosPromise}
 */
export function queryAllByPager(params) {
  return request({
    url: 'rest/api/manager/service',
    method: 'get',
    params
  })
}

export function del(ids) {
  return request({
    url: 'rest/api/manager/service/del',
    method: 'post',
    data: ids
  })
}
export function delFj(ids) {
  return request({
    url: 'rest/api/manager/service/fj/del',
    method: 'post',
    data: ids
  })
}

export function queryAllByFj(params) {
  return request({
    url: 'rest/api/manager/service/fj/list',
    method: 'get',
    params
  })
}

export function edit(data) {
  return request({
    url: 'rest/api/manager/service/update',
    method: 'post',
    data
  })
}
export function queryAllService() {
  return request({
    url: 'rest/api/manager/service/all',
    method: 'get'
  })
}
export default { add, edit, del, delFj }
